home *** CD-ROM | disk | FTP | other *** search
/ PC World Komputer 1997 November / Pcwk1197.iso / LOTUS / Eng-ins / SMASTERS / APPROACH / DB2WWW.MPR / SCRIPT / ApproachDoc / WWW Assistant / Body / btnOpen.s (.txt) < prev    next >
Null Bytes Alternating  |  1997-01-09  |  2KB  |  38 lines

  1. '++LotusScript Development Environment:2:5:(Options):0:66
  2.  
  3. '++LotusScript Development Environment:2:5:(Forward):0:1
  4. Declare Sub Click(Source As Button, X As Long, Y As Long, Flags As Long)
  5. Declare Sub FileOpen
  6.  
  7. '++LotusScript Development Environment:2:5:(Declarations):0:2
  8.  
  9. '++LotusScript Development Environment:2:2:BindEvents:1:129
  10. Private Sub BindEvents(Byval Objectname_ As String)
  11.     Static Source As BUTTON
  12.     Set Source = Bind(Objectname_)
  13.     On Event Click From Source Call Click
  14. End Sub
  15.  
  16. '++LotusScript Development Environment:2:2:Click:1:12
  17. Sub Click(Source As Button, X As Long, Y As Long, Flags As Long)
  18.     Call FileOpen()    
  19. End Sub
  20. '++LotusScript Development Environment:2:2:FileOpen:1:8
  21. Sub FileOpen
  22.     Dim CurDoc As Document
  23.     'Reset the Assistant
  24.     gFlagLoaded = 0
  25.     
  26.     Set CurDoc = CurrentDocument
  27.     'Close the dialog
  28.     Set CurrentWindow.ActiveView = CurrentDocument.Other
  29.     Doevents
  30.     'Show open dialog instead
  31.     CurrentApplication.ApplicationWindow.Domenucommand(IDM_OPEN)
  32.     CurDoc.Activate
  33.     Doevents
  34.     CurrentWindow.visible = False
  35.     Set CurrentWindow.activeview = CurrentDocument.www~ assistant
  36.     'reset error
  37.     Err = 0
  38. End Sub